package com.learn.flyweight.other;

import com.learn.flyweight.Color;
import lombok.extern.slf4j.Slf4j;

/**
 * <p>项目名称: design-pattern </p>
 *
 * <p>文件名称: OtherChessman </p>
 *
 * 围棋棋子类：抽象享元类
 */
@Slf4j
public abstract class OtherChessman {

    abstract Color getColor();

    public void display(Position position){
        log.info("棋子颜色为：{},位置为【{}，{}】。" , this.getColor().getDetail(),position.getX(),position.getY());
    }
}
